// event_on_muti.js

const EventEmitter = require('events');

class MyEmitter extends EventEmitter {}

const myEm = new MyEmitter();

let m = 0;
myEm.on('event', () => {
    console.log(++m)
});

myEm.emit('event')

myEm.emit('event')
